<%@page pageEncoding="UTF-8"%>
<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles" %>
<%@ taglib prefix="s" uri="/struts-tags" %> 
<%@ taglib prefix="sx" uri="/struts-dojo-tags" %>
<%@ page import="com.appsindy.reserv.ReservConstants" %>
<sx:head parseContent="true"/>

<html> 
<head>
<meta http-equiv="Pragma" content="text/html; charset=UTF-8" content="no-cache"> 
<link rel="stylesheet" href="css/demo_page.css" media="screen"></link>
<link rel="stylesheet" href="css/demo_table.css" media="screen"></link> 
<title>Room Reserve Details</title>
	
<style type="text/css">
	.button { width: 80px;}
	.list { width: 200px; }
	body {
		padding: 5px 5px 5px 5px;
	}
	.tHead{
		color: #000000;
		width:100%;
		table-layout:fixed;
		border-top:1px solid #000000;
		border-left:1px solid #000000;
		border-right:1px solid #000000;
		/*font: bold 14 "MS Sans Serif","Microsoft Sans Serif";*/
		background-color: #CCFFFF;
		text-align:center;
	}
	.tBody{
		color: #000000;
		table-layout:fixed;
		background-color: #FFFFFF;
		/*font: 14 "MS Sans Serif","Microsoft Sans Serif";*/
	}
</style>

<script type="text/javascript">            
<!--
	window.focus();
	if (!window.opener)
		window.document.write();

	var openerObj = window.opener;

	function gotoGroupDetail(headerId, groupId){
		var opennerForm 						= openerObj.frmReserveInfoRoom;
		opennerForm.serviceHeaderIdPopup.value 	= headerId;
		opennerForm.groupResultPopup.value		= groupId;
		openerObj.toReserveInfoRoom();
		window.close();			
	}
//-->
</script>
</head>

<body background="images/top_page_bg.jpg">

<font color="#FFFFFF">Reserve by &nbsp; <s:property value="groupResultNamePopup" /></font>
<s:form id="frmGroupResultPopup" action="reserveOverview_toGroupResultPopup.action" method="POST" theme="simple">
<table cellpadding="2" cellspacing="0" border="0" width="100%" align="center"
	   style="background-color:white; border:solid 1px #5AAAFA">
<tr>
	<td align="center">
		<div style="height:240px; width:450px; padding-top: 5px; overflow:scroll; overflow-x:hidden">
		<table width="90%" cellspacing="1" bgcolor="#111111">
		<tr bgcolor="#FFFFFF" style="background-image: url('images/gradtblhdr.gif')">
			<td>&nbsp;</td>
			<td><s:label key="reserve.dialog.jobnumber" /></td>
			<td><s:label key="reserve.dialog.daterange" /></td>
		</tr>
		<s:iterator value="groupResultPopupList" >
		<tr bgcolor="#FFFFFF" onclick="gotoGroupDetail('<s:property value="id"/>', '<s:property value="groupId"/>')" style="cursor:hand;" onmouseover="this.bgColor='#CCFFFF';" onmouseout="this.bgColor='#FFFFFF'">
			<td>
				<s:if test="status == 'RESERVED'">
					<img alt="" src="${pageContext.request.contextPath}/images/status_R.png">
				</s:if>
				<s:elseif test="status == 'BOOKED'">
					<img alt="" src="${pageContext.request.contextPath}/images/status_B.png">
				</s:elseif>
				<s:elseif test="status == 'CHECKIN'">
					<img alt="" src="${pageContext.request.contextPath}/images/status_C.png">
				</s:elseif>
				<s:elseif test="status == 'CHECKOUT'">
					<img alt="" src="${pageContext.request.contextPath}/images/status_O.png">
				</s:elseif>	
			</td>
			<td><s:property value="name"/></td>
			<td><s:property value="startDate"/>-<s:property value="endDate"/></td>
		</tr>
		</s:iterator>
		</table>
        </div>
	</td>
</tr>
<tr>
	<td align="center">
    	<%--input type="button" value="<s:text name="reserve.dialog.ok" />" class="button" onclick="//submitData()" id="btnOk" /--%>
		<input type="button" value="<s:text name="reserve.dialog.cancel" />" onclick="window.close()" class="button" />
		<img id="groupResultIndicator" src="${pageContext.request.contextPath}/images/indicator.gif" alt="Loading..." style="visibility:hidden"/>  
	</td>
</tr>
</table>
</s:form>

</body>
</html>
